package org.apache.struts.admin.action;

import org.apache.struts.admin.model.Ward;
import org.apache.struts.ehr.medical_records.model.ReplyMessage;

import com.opensymphony.xwork2.ActionSupport;

public class AddNewWardFormAction extends ActionSupport{

	private Ward ward;
	private ReplyMessage replyMessage;
	
	public ReplyMessage getReplyMessage() {
		return replyMessage;
	}

	public Ward getWard() {
		return ward;
	}

	public void setWard(Ward ward) {
		this.ward = ward;
	}
	
	public String execute() throws Exception {
		replyMessage=new ReplyMessage();
		replyMessage.setMessage("empty");
		if(ward!=null && ward.getWardNo()!=null && ward.getNoOfBeds()!=null){
			String x="Ward no : "+ward.getWardNo()+" , No of beds : "+ward.getNoOfBeds();
			replyMessage.setMessage(x);
		}
		return SUCCESS;
	}
	

}
